<?php
/**
 * 安全防范之DDos
 * Created by PhpStorm.
 * User: Egor <http://gitee.com/seosite>
 * Date: 2018/5/28
 * Time: 下午4:01
 * Updatetime:
 * updater：
 */
namespace Applet\Controller;
use Think\Controller;

class DdosController extends Controller{




    public function index()
    {

        var_dump(C('REDIS_PORT'));

        $redis = new \Redis();
        $redis->connect('127.0.0.1');

//        $redis->set('Egor','摩羯男，25岁，上海嘉定，php');

        $redis->hMset(1,[1=>'a','2'=>'b']);

    }


    public function hget()
    {
        $redis = new \Redis();
        $redis->connect('127.0.0.1');

        $a = $redis->hGet(1,'2');
        var_dump($a);
    }



}